﻿CREATE TABLE [dbo].[Role]
(
	[Id] [dbo].[Id] NOT NULL  IDENTITY(1000000000, 1), 
    [Name] [dbo].[Name] NOT NULL, 
    [Description] [dbo].[Description] NOT NULL, 
    [EnvironmentId] [dbo].[Id] NULL, 
    [CreateId] [dbo].[Name] NOT NULL , 
    [CreateDateTime] [dbo].[CreateModifiedDateTime] NOT NULL , 
    [ModifiedId] [dbo].[Name] NOT NULL , 
    [ModifiedDateTime] [dbo].[CreateModifiedDateTime] NOT NULL , 
    CONSTRAINT [PK_Role] PRIMARY KEY ([Id]), 
    CONSTRAINT [AK_Role_Name] UNIQUE (Name), 
    CONSTRAINT [FK_Role_Environment_EnvironmentId] FOREIGN KEY (EnvironmentId) REFERENCES Environment(Id)
)
